#ifndef MAINWINDOW_H
#define MAINWINDOW_H

#include <QMainWindow>
#include <QGridLayout>
#include <QScrollArea>
#include <QAction>
#include <QMap>
#include "checkablemenuaction.h"

QT_BEGIN_NAMESPACE
namespace Ui { class MainWindow; }
QT_END_NAMESPACE

class MainWindow : public QMainWindow
{
    Q_OBJECT

public:
    MainWindow(QWidget *parent = nullptr);
    ~MainWindow();

private slots:
    void selectFile();
    void selectFolder();
    void onFeatureActionToggled(bool checked);


private:
    Ui::MainWindow *ui;
    QScrollArea *scrollArea;
    QWidget *contentWidget;
    QGridLayout *gridLayout;

    QString *aaa;

    QMap<QString, QAction*> featureActions;
    void createFeatureMenu();
    void loadFeatureSettings();
    void saveFeatureSettings();

    void clearImages();
    void displayImage(const QString &filePath);
    void displayImagesFromFolder(const QString &folderPath);
};
#endif // MAINWINDOW_H
